package com.xiaomo.gitee.datamanager.entity.menu;

import com.alibaba.fastjson2.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;

@TableName("main_menu")
@Data
@Schema(name = "主菜单栏目模型",title = "主菜单栏目模型")
public class MainMenuPO implements Serializable {

    @TableId("id")
    @Schema(
            title = "id",
            description = "栏目ID",
            format = "number"
    )
    private Integer id;

    @TableField("name")
    @Schema(
            title = "name",
            description = "栏目名称",
            format = "string"
    )
    private String name;

    @TableField("description")
    @Schema(
            title = "description",
            description = "栏目描述",
            format = "string"
    )
    private String description;

    @TableField("perm")
    @JsonIgnore
    @JSONField(serialize = false)
    @Schema(
            hidden = true
    )
    private String perm;

    @TableField("path")
    @Schema(
            title = "path",
            description = "访问路径",
            format = "string"
    )
    private String path;

    @Serial
    private static final long serialVersionUID = 1L;
}
